package com.smart.manager.union.egg.body;

import com.smart.common.entities.core.BaseSearch;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;


/**
 * 帮助
 *
 * @author Leo
 * @date 2023/08/16
 */
public class RUnionEggProduct {

    @Data
    @EqualsAndHashCode(callSuper = true)
    @ApiModel("RPopHelp1")
    public static class SearchBody extends BaseSearch {

        @ApiModelProperty("商品标题")
        private String title;


    }


    @Data
    @ApiModel("RPopHelp2")
    public static class EditBody implements Serializable {

        @ApiModelProperty("商品标题")
        @NotBlank(message = "商品标题不能为空")
        private String title;

        @ApiModelProperty("鸡蛋数量")
        @NotNull(message = "鸡蛋数量不能为空")
        @Min(value = 1, message = "鸡蛋数量不能小于1")
        private Integer eggQuantity;


        @ApiModelProperty("需要支付的运费金币")
        @NotNull(message = "需要支付的运费金币不能为空")
        private Integer postFee;


    }


}
